package com.letfox.user.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.letfox.user.dao.DictionaryDao;
import com.letfox.user.model.UDictionary;
import com.letfox.user.service.DictionaryService;

@Service
public class DictionServiceImpl implements DictionaryService {

	@Autowired
	private DictionaryDao dictionaryDao;

	@Override
	public int save(UDictionary dictionary) {
		return dictionaryDao.insert(dictionary);
	}

	@Override
	public int update(UDictionary dictionary) {
		return dictionaryDao.update(dictionary);
	}

	@Override
	public int deleteById(Long id) {
		return dictionaryDao.deleteById(id);
	}

	@Override
	public int deleteByIds(String ids) {
		return dictionaryDao.deleteByIds(ids);
	}

	@Override
	public UDictionary getById(Long id) {
		return dictionaryDao.selectById(id);
	}

	@Override
	public List<UDictionary> getList(UDictionary dictionary) {
		return dictionaryDao.selectList(dictionary);
	}

}
